﻿@model ITProject.WebUI.Models.Message.MessageSendViewModel

@{
    ViewBag.Title = "Wysyłanie wiadomosci";
    Layout = "~/Views/Shared/_Layout.cshtml";
}


<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

@using (Html.BeginForm()) {
    @Html.ValidationSummary(true)
    <fieldset>
        <legend> Wiadomość do użytkownika @Model.Receiver </legend>
        <div class="editor">
        <div class="editor-label">
            @Html.LabelFor(model => model.Subject) <span class="validation">*</span>
        </div>
        <div class="editor-field">
        <p class="validation">@Html.ValidationMessageFor(model => model.Subject)</p>
            @Html.TextBoxFor(model => model.Subject, new { @class = "input" })
            
        </div>
        </div>
        <div class="editor">
        <div class="editor-label">
            @Html.LabelFor(model => model.Text) <span class="validation">*</span>
        </div>
        <div class="editor-field">
            <p class="validation">@Html.ValidationMessageFor(model => model.Text)</p>
            @Html.TextAreaFor(model => model.Text, new { @class = "input" })
            
        </div>
        </div>
        <div class="editor">
        <div class="editor-label">
            @Html.LabelFor(model => model.NeedReadConfirmation)
        </div>
        <div class="editor-field">
            @Html.CheckBoxFor(model => model.NeedReadConfirmation, new { @class = "input" })
            @Html.ValidationMessageFor(model => model.NeedReadConfirmation)
        </div>
        </div>
        @Html.HiddenFor(model => model.IdSender)
        @Html.HiddenFor(model => model.Receiver)

         <p class="validation" style="padding-left:50px">        
        *pola wymagane
        </p>
        <div class="DSubmit">
            <input type="reset" class="button" value="Wyczyść" />
            <input type="submit" class="button" value="Wyślij" />
        </div>
    </fieldset>
}


